package tech.aistar.service.center.impl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import tech.aistar.entity.RealName;
import tech.aistar.mapper.center.RealNameMapper;
import tech.aistar.service.center.IRealNameService;

import javax.transaction.Transactional;

/**
 * Created by 23827 on 2019/10/11.
 */
@Service
@Transactional
public class RealNameServiceImpl implements IRealNameService {
    @Autowired
    private RealNameMapper realNameMapper;
    @Override
    public void save(RealName realName) {
        realNameMapper.save(realName);
    }

    @Override
    public RealName getById(Integer id) {
        RealName realName = realNameMapper.getById(id);
        return realName;
    }

    @Override
    public RealName findByUserId(Integer user_id) {
        RealName realName = realNameMapper.findByUserId(user_id);
        return realName;
    }
}
